package com.design.cjm.behavioral.visitor.example;

/**
 * @Author: Jie Ming Chen
 * @Date: 2018/9/26
 * @Version 1.0
 */
public class TestApp {

    public static void main(String[] args) {
        ObjectStructure object = new ObjectStructure();

        object.attach(new ConcreteElementA());
        object.attach(new ConcreteElementB());

        ConcreteVisitor1 v1 = new ConcreteVisitor1();
        ConcreteVisitor2 v2 = new ConcreteVisitor2();

        object.accept(v1);
        object.accept(v2);
    }
}
